<%--
  Created by IntelliJ IDEA.
  User: admin
  Date: 2018/11/29
  Time: 14:58
  To change this template use File | Settings | File Templates.
--%>
<%@ page contentType="text/html;charset=UTF-8" language="java" %>
<%
    String path = request.getContextPath();
    String basePath = request.getScheme() + "://" + request.getServerName() + ":" + request.getServerPort() + path + "/";
%>
<html>
<head>
    <style type="text/css">
        #rec_body {padding: 15px;}
        .rec_input{width: 90%;}
    </style>
    <base href="<%=basePath%>"/>
    <title>添加交往记录</title>
    <link rel="stylesheet" href="static/commons/layui/css/layui.css" media="all" />
    <link rel="stylesheet" href="static/css/public.css" media="all" />
</head>
<body id="rec_body">

<form action="/contact-record/save" class="layui-form padr45" method="post" autocomplete="off">

    <input type="text" name="customerId" value="${param.id}" readonly class="layui-input layui-disabled contact-input" style="visibility: hidden;height: 3px" />
    <div class="layui-form-item">
        <label class="layui-form-label">时间</label>
        <div class="layui-input-block">
            <input type="text" name="contactTime" lay-verify="required" class="layui-input rec_input"  id="time1" placeholder="请单击并选择时间">
        </div>
    </div>

    <div class="layui-form-item">
        <label class="layui-form-label">地点</label>
        <div class="layui-input-block">
            <input type="text" name="place" lay-verify="required"  class="layui-input rec_input" placeholder="请输入地点">
        </div>
    </div>

    <div class="layui-form-item">
        <label class="layui-form-label">概要</label>
        <div class="layui-input-block">
            <input type="text" name="outline" lay-verify="required"  class="layui-input rec_input" placeholder="请输入概要">
        </div>
    </div>

    <div class="layui-form-item">
        <label class="layui-form-label">备注</label>
        <div class="layui-input-block">
            <input type="text" name="remarks" class="layui-input rec_input">
        </div>
    </div>

    <div class="layui-form-item">
        <label class="layui-form-label">详细信息</label>
        <div class="layui-input-block">
            <textarea name="detailedInfo" class="layui-textarea rec_input"></textarea>
        </div>
    </div>

    <div class="layui-form-item">
        <div class="layui-input-block">
            <button class="layui-btn" lay-submit lay-filter="btn_submit">保存</button>
            <button type="reset" class="layui-btn layui-btn-warm">重置</button>
            <button type="button" class="layui-btn layui-btn-danger btn_close">关闭</button>
        </div>
    </div>


</form>




<script type="text/javascript" src="static/commons/layui/layui.js"></script>
<script type="text/javascript" src="static/js/contact-record/contact-rec.js"></script>
<%--日期控件,要放置于layuii.js后--%>
<script>
    layui.use('laydate', function(){
        var laydate = layui.laydate;
        laydate.render({
            elem: '#time1',//指定元素
            type: 'date',
            done: function(value, date, endDate){
                console.log(value);//得到日期生成的值，如：2017-08-18
                console.log(typeof value);
    }
        });
    });
</script>
</body>
</html>
